package com.sunday.boot3.user.center.rest.api;

import com.sunday.common.core.remoting.rest.page.PageVO;
import com.sunday.common.core.remoting.rest.response.RestResponse;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.Parameter;
import io.swagger.v3.oas.annotations.enums.ParameterIn;
import io.swagger.v3.oas.annotations.tags.Tag;
import com.sunday.boot3.user.center.rest.vo.role.PageRoleReqVO;
import com.sunday.boot3.user.center.rest.vo.role.RemoveRoleReqVO;
import com.sunday.boot3.user.center.rest.vo.role.SaveRoleReqVO;
import com.sunday.boot3.user.center.rest.vo.role.UpdateRoleReqVO;
import com.sunday.boot3.user.center.rest.vo.role.PageRoleResVO;
import org.springframework.web.bind.annotation.DeleteMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.PutMapping;
import org.springframework.web.bind.annotation.RequestBody;

/**
 * @Description: 角色表 Web 层
 * @author: zsy
 * @Create: 2024/09/23 10:06:39
 */
@Tag(name = "角色表")
public interface RoleApi {

    /**
     * 访问路径
     */
    String ACCESS_PATH = "/role";

    /**
     * @Description: 新增 角色表 数据
     * @Param: [saveRoleReqVO]
     * @Return: com.sunday.common.core.remoting.rest.response.RestResponse
     * @author: zsy
     * @Create: 2024/09/23 10:06:39
     */
    @Operation(summary = "新增", description = "新增 角色表 数据")
    @PostMapping("/save")
    RestResponse save(@Parameter(description = "新增 角色表VO", in = ParameterIn.DEFAULT) @RequestBody SaveRoleReqVO saveRoleReqVO);

    /**
     * @Description: 删除 角色表 数据
     * @Param: [removeRoleReqVO]
     * @Return: com.sunday.common.core.remoting.rest.response.RestResponse
     * @author: zsy
     * @Create: 2024/09/23 10:06:39
     */
    @Operation(summary = "删除", description = "删除 角色表 数据")
    @DeleteMapping("/remove")
    RestResponse remove(@Parameter(description = "删除 角色表VO", in = ParameterIn.DEFAULT) @RequestBody RemoveRoleReqVO removeRoleReqVO);

    /**
     * @Description: 修改 角色表 数据
     *
     * @Param: [updateRoleReqVO]
     * @Return: com.sunday.common.core.remoting.rest.response.RestResponse
     * @author: zsy
     * @Create: 2024/09/23 10:06:39
     */
    @Operation(summary = "修改", description = "修改 角色表 数据")
    @PutMapping("/update")
    RestResponse update(@Parameter(description = "修改 角色表VO", in = ParameterIn.DEFAULT) @RequestBody UpdateRoleReqVO updateRoleReqVO);

    /**
    * @Description: 获取 角色表 分页列表数据
    *
    * @Param: [pageRoleReqVO]
    * @Return: com.sunday.common.core.remoting.rest.response.RestResponse<com.sunday.common.core.remoting.rest.page.fegin.FeginPageResultVO<com.sunday.boot3.user.center.rest.vo.role.PageRoleResVO>>
    * @author: zsy
    * @Create: 2024/09/23 10:06:39
    */
    @Operation(summary = "列表数据", description = "获取 角色表 分页列表数据")
    @PostMapping("/page")
    RestResponse<PageVO<PageRoleResVO>> page(@Parameter(description = "角色表VO", in = ParameterIn.DEFAULT) @RequestBody PageRoleReqVO pageRoleReqVO);

}